// pages/welcome/welcome.js
Page({
  data: {
    second:3,
    image:"/images/bg/splash.png"
  },
  doJump(){
    wx.switchTab({
      url: '/pages/index/index',
    })
  },
  onLoad(options){
    var ins = setInterval(()=>{
      if(this.data.second<=0){
        clearInterval(ins)
        wx.switchTab({
          url: '/pages/index/index',
        })
      }else{
        this.setData({
          second:this.data.second-1
        })
      }
    },1000)
  }
})